Skip to content

Remove Transducers.jl dependency - #201

Merged
penelopeysm merged 2 commits into
mainfrom
dmw/rm_transducers
Apr 5, 2026
Merged

Remove Transducers.jl dependency#201
penelopeysm merged 2 commits into
mainfrom
dmw/rm_transducers

Conversation

@devmotion

@devmotion devmotion commented Mar 26, 2026

Copy link
Copy Markdown
Member

Closes #200.

Summary

Remove the internal (unexported) Sample transducer and the Transducers.jl dependency, which brought in 11 unique transitive dependencies (Accessors, ArgCheck, Baselet, CompositionsBase, ConstructionBase, DefineSingletons, InitialValues, Markdown, MicroCollections, SplittablesBase, Tables).

The equivalent steps() / Stepper iterator interface remains available for lazy/streaming MCMC sampling.

Options considered

Three approaches were evaluated:

1. Package extension

Move Sample to ext/AbstractMCMCTransducersExt.jl, make Transducers a weak dep.

Pros Cons
Not breaking for actual users Still carries maintenance burden for unused code
Eliminates transitive deps for most users Must still track Transducers compat bounds
Follows existing extension pattern in this repo Requires constructor-forwarding plumbing for AbstractMCMC.Sample

2. Separate package

Create AbstractMCMCTransducers.jl.

Pros Cons
Complete decoupling Highest maintenance overhead (new repo, CI, registry)
Overkill for ~100 lines of code nobody uses

3. Remove completely (chosen)

Pros Cons
Simplest change — pure deletion Removes AbstractMCMC.Sample (internal, unexported)
Eliminates 11 transitive deps immediately
Zero ongoing maintenance burden
steps() provides equivalent functionality
No known downstream users (GitHub search confirmed)
Removes reliance on sparsely-maintained upstream

Rationale: No known users, not exported, equivalent functionality exists via steps(), and the issue author doubts anyone uses it. Option 1 adds complexity to preserve dead code; Option 2 is overkill.

Test plan

  • CI passes (all remaining tests should be unaffected)
  • using AbstractMCMC loads without error
  • Transducers no longer appears in resolved Manifest

🤖 Generated with Claude Code

@github-actions

Copy link
Copy Markdown
Contributor

AbstractMCMC.jl documentation for PR #201 is available at:
https://TuringLang.github.io/AbstractMCMC.jl/previews/PR201/

Remove the internal (unexported) `Sample` transducer and the Transducers.jl
dependency, which brought in 11 transitive dependencies. The equivalent
`steps()` / `Stepper` iterator interface remains available for lazy/streaming
MCMC sampling.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@devmotion
devmotion force-pushed the dmw/rm_transducers branch from 1bf6f85 to 23e0e9d Compare March 26, 2026 23:43

@penelopeysm penelopeysm left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @devmotion! Quite happy to remove it. There are a few remaining references to transducers in the docs, I'll go ahead and remove them too.

@penelopeysm
penelopeysm merged commit 237025c into main Apr 5, 2026
15 checks passed
@penelopeysm
penelopeysm deleted the dmw/rm_transducers branch April 5, 2026 14:13
@codecov

codecov Bot commented Apr 5, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 0.00%. Comparing base (0f67b29) to head (6fcf4b5).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@     Coverage Diff     @@
##   main   #201   +/-   ##
===========================
===========================

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Move Transducers support to an extension?

2 participants